import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

public class MathUtil {
    public static void main(String args[]){

        System.out.println(2110000+Math.atan(0.025 ) * 450000);

        System.out.println(2110000+Math.atan(120/40.0)*450000+1932000/150.0/120);

        System.out.println(getUTCTime(FormatISO8601) );
        Boolean isRecordType = false;

        //if( isRecordType == 0)
            System.out.println("is zero");

        String rate= "LGD3 - 44%";
        rate = rate.replaceAll("^[^A-Z]+|[b-z]+","");
        return  ;
    }




    public static  final String FormatISO8601 = "yyyy-MM-dd'T'HH:mm:ss'Z'";
    public static Date getUTCTime(){
        Calendar cal = Calendar.getInstance();

        int offset = cal.get(Calendar.ZONE_OFFSET);

        int dstoff = cal.get(Calendar.DST_OFFSET);

        cal.add(Calendar.MILLISECOND, - (offset + dstoff));
        return cal.getTime();

    }

    public static String getUTCTime(String format){
        String formatDate = format(getUTCTime(), format);
        return formatDate;
    }

    public static String format(Date date, String pattern) {
        String returnValue = "";
        if (date != null) {
            SimpleDateFormat df = new SimpleDateFormat(pattern);
            returnValue = df.format(date);
        }
        return (returnValue);
    }
}
